Previous Book Contents Book Index Next

Inside Macintosh: QuickTime /
Chapter 2 - Movie Toolbox / Movie Toolbox Reference
Functions That Modify Movie Properties / Working With Movie User Data


AddUserDataText

The AddUserDataText function allows your application to place language-tagged text into an item in a user data list. You specify the user data list and item, the data to be added, the data's type value, and the language code of the data.

pascal OSErr AddUserDataText (UserData theUserData, Handle data, 
                              OSType udType, long index, 
                              short itlRegionTag);
theUserData
Specifies the user data list for this operation. You obtain this list reference by calling the GetMovieUserData, GetTrackUserData, or GetMediaUserData function (described on page 2-215, page 2-216, and page 2-217, respectively).
data
Contains a handle to the data to be added to the user data list.
udType
Specifies the type that is to be assigned to the new item.
index
Specifies the item to which the text is to be added. This parameter must specify an item in the user data list identified by the parameter theUserData.
itlRegionTag
Specifies the region code of the text to be added. If there is already text with this region code in the item, the function replaces the existing text with the data specified by the data parameter. See Inside Macintosh: Text for more information about language and region codes.
DESCRIPTION
The Movie Toolbox places the specified data into the user data item. If the item does not exist when you call this function, the Movie Toolbox creates a new item for you (this is true only if the item you are adding is the first item in the list; otherwise, you must create the item yourself).

ERROR CODES
userDataItemNotFound-2026Cannot locate this user data item
Memory Manager errors


Previous Book Contents Book Index Next

© Apple Computer, Inc.
6 JUL 1996